package com.itheima.reggie.service;

import com.itheima.reggie.entity.Category;
import com.itheima.reggie.entity.Page;

import java.util.List;

public interface CategoryService {
    //分页
    Page<Category> selectByPage(Integer page,Integer pageSize);
    //新增菜品分类
    Boolean add(Category category);
    //修改
    Boolean update(Category category);
    //删除
    Boolean delete(Long id);
    //查找菜品类型id
    Category selectTypeById(Long type);
    //查询所有type=1的分类
    List<Category> selectAllByType(Integer type);
    //根据category_id查找
    Category selectByCategoryId(Long id);

}
